<%--

<!------------------------------------------------------------------------------
 - Copyright 2007 CORE Solutions Limited
 - All rights reserved.
 - PROPRIETARY AND CONFIDENTIAL INFORMATION.
 - Use is subject to license terms.
 -
 - FUNCTION ID      :   CATALOG_SECURITY
 - AUTHOR           :   Saint Peng 
 - DATE CREATE      :   2007/03/29
 - DESCRIPTION      :   a CHILD TAB JSP file for the function, CATALOG_SECURITY
 -                  :   
 -                  :   
 -                  :   
 -
 - MODIFICATION HISTORY:
 - DATE         AUTHOR          VERSION NO.         COMMENT
 - -----------  --------------  ------------------  -------------------
 - 2007/03/29   Saint Peng      1.0                 source is generated.
 -
 -
 -
------------------------------------------------------------------------------->

--%>
<%@ include file="/jsp/com/erp/app/common/jsp/directives_include.jsp"%>

<%@ page import="com.erp.app.catalog.catalogSecurity.vo.CatalogSecurityDtlVo"%>
<%@ page import="com.erp.app.catalog.catalogSecurity.web.CatalogSecurityMaintenanceAction"%>
<%@ page import="com.erp.app.catalog.catalogSecurity.web.CatalogSecurityMaintenanceForm"%>
<%@ page import="com.erp.app.catalog.catalogSecurity.web.CatalogSecurityDtlRow"%>

<%@ include file="/jsp/com/erp/app/common/jsp/html_include.jsp"%>

<% try { %>

<jsp:useBean id="catalogSecurityMaintenanceForm" scope="session" type="com.erp.app.catalog.catalogSecurity.web.CatalogSecurityMaintenanceForm" />

<%
ArrayList catalogSecurityDtlList = catalogSecurityMaintenanceForm.getMultiRows(CatalogSecurityMaintenanceAction.TAB_IDX_DTL);
pageContext.setAttribute("catalogSecurityDtlList", catalogSecurityDtlList);

rowReadOnly = false;
%>

<chtml:button form="catalogSecurityMaintenanceForm" pageEvent="<%=CatalogSecurityMaintenanceAction.ACTION_ADD_RETRIEVE_DTL%>" styleClass="button1" disabled="<%=String.valueOf(rowReadOnly)%>"/>

<!-- MUST use the following example to mark fields as mandatory field inputs-->
<!--
<td class="grid_header" nowrap><span class="mandatory_label">
<bean:message key="label.general.mandatory.field"/>
...</span></td>
-->
<%
TableSchema[] childTsArray = catalogSecurityMaintenanceForm.getChildTs();
TableSchema childTs = childTsArray[CatalogSecurityMaintenanceAction.TAB_IDX_DTL];
%>

<table class="table_grid">

	<tr class="grid_header">
		<%
			webLabel = childTs.getDisplayWebLabelByObjectId("LBL_DTL_DELETE");
		%>
		<td class="grid_header_col_narrow" nowrap>
			<%=webLabel%>
		</td>
		<td class="grid_header_col" nowrap>
			<%
			webLabel = childTs.getDisplayWebLabelByObjectId("LBL_CATALOG_ID");
			%>
			<%=webLabel%>
		</td>
		<td class="grid_header_col" nowrap>
			<%
			webLabel = childTs.getDisplayWebLabelByObjectId("LBL_CATALOG_DESC");
			%>
			<%=webLabel%>
		</td>
		<td class="grid_header_col" nowrap>
			<%
			webLabel = childTs.getDisplayWebLabelByObjectId("LBL_CATALOG_LEVEL");
			%>
			<%=webLabel%>
		</td>
		<%--<td class="grid_header_col" nowrap>
			<%
			webLabel = childTs.getDisplayWebLabelByObjectId("LBL_CATALOG_TREE");
			%>
			<%=webLabel%>
		</td> --%>
	</tr>

	<logic:iterate id="catalogSecurityDtlRow" name="catalogSecurityDtlList" indexId="idx" length="<%=String.valueOf(ProjectConstants.MAX_DISPLAY)%>" offset="<%=String.valueOf(catalogSecurityMaintenanceForm.getSidx())%>">

	<%
		CatalogSecurityDtlRow row = (CatalogSecurityDtlRow) catalogSecurityDtlRow;
	%>

	

	<tr <%=(idx.intValue()%2 == 0)? "class='grid_result1'": "class='grid_result2'"%>>
		<td nowrap>
		<chtml:button form="catalogSecurityMaintenanceForm" deleteButton="true" multiRow="catalogSecurityDtlRow" pageEvent="<%=CatalogSecurityMaintenanceAction.ACTION_DEL_RETRIEVE_DTL%>" pageEventSrc="<%=String.valueOf(idx)%>" styleClass="button1" disabled="<%=String.valueOf(rowReadOnly)%>"/>	
		</td>
		<td nowrap>
			<html:text useExtensions="true" uiType="write" name="catalogSecurityDtlRow"  property="dtlNodeId"/>
		</td>
		<td nowrap>
			<html:text useExtensions="true" uiType="write" name="catalogSecurityDtlRow"  property="dtlCatalogName"/>
		</td>
		<td nowrap>
			<html:text useExtensions="true" uiType="write" name="catalogSecurityDtlRow"  property="dtlCatalogLevel"/>
		</td>
	</tr>
	

		<html:hidden property="idx" value="<%=row.getIdx()%>" />
		<html:hidden property="rowMode"  value="<%=row.getRowMode()%>"/>

	</logic:iterate>

</table>


<% } catch(Exception e) { e.printStackTrace(); } %>
